<#include "/common/common.ftl" encoding="UTF-8">
	<link href="${staticUrl}/js/validate/jquery.validate.css" type="text/css" rel="stylesheet" />
	<script src="${staticUrl}/js/validate/jquery.validate.js" type="text/javascript"></script>
	<script src="${staticUrl}/js/validate/messages_cn.js" type="text/javascript"></script>
	<link href="${staticUrl}/css/form.css" type="text/css" rel="stylesheet" />
	
	<#assign action="user">
	<script>
		$(document).ready(function(){
			//聚焦第一个输入框
			$("#loginName").focus();
			//为inputForm注册validate函数
			$("#inputForm").validate({
				rules: { 
          name: "required",
          password: {
    					required: true,
    					minlength:3
    			}, 
    			passwordConfirm: {
    					equalTo:"#password"
    			},
    			email:"email"
				},
				messages: {
					passwordConfirm: {
						equalTo: "输入与上面相同的密码"
					}
				}
			});
		});

	</script>
</head>
<body>
<div class="title">基本信息</div>
<div id="inputContent">
<form id="inputForm" action="${action}!selfSave.action" method="post">
<input type="hidden" name="id" value="${(id)?if_exists}" />
<table class="content">
	<tr>
		<@ftlMacro.detailText descript="登录名" textShow="${code?if_exists}"/>
	</tr>
	<tr>
		<@ftlMacro.inputText name="name" descript="用户名" textShow="${name?if_exists}"/>
	</tr>
	<tr>
		<@ftlMacro.inputPassword name="password" descript="密码" textShow="${password?if_exists}"/>
	</tr>
	<tr>
		<@ftlMacro.inputPassword name="passwordConfirm" descript="确认密码" textShow="${password?if_exists}"/>
	</tr>
	<tr>
		<@ftlMacro.inputText name="email" descript="邮箱" textShow="${email?if_exists}"/>
	</tr>
	<tr>
		<@ftlMacro.detailText descript="部门" textShow="${dept.name?if_exists}"/>
	</tr>
	<tr class="button">
		<td colspan="2">
			<input type="submit" value="提交" />&nbsp; 
			<input type="button" value="取消" onclick="history.back()"/>
		</td>
	</tr>
	<tr>
		<td colspan="2">
		</td>
	</tr>
</table>
</form>
</div>
</body>
</html>